from lxml import etree, html



tree = html.fromstring(open('123.html', encoding='utf-8').read())
title = tree.cssselect('title')
print(title)
lis = tree.cssselect('li')
for li in lis:
    print(li.text, li.attrib, li.tag)